package com.snowy.hidden.user.mapper;

import com.snowy.framework.common.base.mapper.BaseMapper;
import com.snowy.hidden.user.domain.model.SysUser;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

/**
 * 用户(SysUser)表数据库访问层
 *
 * @author makejava
 * @since 2023-11-29 23:33:40
 */
@Mapper
public interface SysUserMapper extends BaseMapper<SysUser> {
    /**
     * 根据手机号查询用户信息
     * @param phone
     * @return
     */
    @Select("select * from SYS_USER where DELETE_FLAG='NOT_DELETE' and USER_STATUS='ENABLE' and PHONE=#{phone} limit 1")
    SysUser getByPhone(@Param("phone")String phone);
}
